Repository navigation
test(node): Batch Vercel AI integration scenarios - #26486
nicohrubec wants to merge 1 commit into
Conversation
f64550f to
9873ee1
Compare
899b943 to
8b9805b
Compare
9873ee1 to
08325ff
Compare
size-limit report 📦Compared: e87929b (PR test merge using feat/batch-integration-runner at 97918c6) Against: ef89ae2 (feat/batch-integration-runner) · base run #67338
|
08325ff to
7ed9907
Compare
7ed9907 to
a11ee99
Compare
9a01fea to
16e37e1
Compare
| runner.collectStreamedSpansUntilSegment( | ||
| span => span.name === 'main' && span.attributes['test.scenario']?.value === name, | ||
| ), | ||
| ); |
There was a problem hiding this comment.
Span collectors can miss child spans
Medium Severity
Batched generation and streaming tests wait with collectStreamedSpansUntilSegment, which resolves as soon as the matching main segment arrives. Child gen_ai spans that land in a later envelope are dropped, so later assertions on generate_content, tools, and usage can flake depending on flush order.
Additional Locations (1)
Triggered by project rule: PR Review Guidelines for Cursor Bot
Reviewed by Cursor Bugbot for commit a11ee99. Configure here.
Co-Authored-By: OpenAI Codex <codex@openai.com>
a11ee99 to
90da2ec
Compare
16e37e1 to
97918c6
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 90da2ec. Configure here.
| ); | ||
| expect(generateContentSpans).toHaveLength(3); | ||
|
|
||
| const toolSpan = spans.find(span => span.attributes[SENTRY_OP]?.value === 'gen_ai.execute_tool'); |
There was a problem hiding this comment.
Tests use string-literal span ops
Low Severity
This file already imports GEN_AI_INVOKE_AGENT and GEN_AI_GENERATE_CONTENT from @sentry/conventions/op, but new and moved assertions still compare SENTRY_OP to string literals such as 'gen_ai.invoke_agent', 'gen_ai.generate_content', and 'gen_ai.execute_tool'. This was flagged because the review rules require integration tests in files that already import @sentry/conventions/op to use those constants for span ops.
Additional Locations (2)
Reviewed by Cursor Bugbot for commit 90da2ec. Configure here.


What
Share processes across compatible Vercel AI scenarios within the generation and streaming suites.
Why
Each short AI scenario previously started the SDK and fixture application again. Run compatible scenarios together while retaining the version, recording-setting and module-format boundaries and the separate assertion cases.
Depends on #26493.
Current-develop benchmark (Nov 20; single runs). Times are the slowest integration test step across six shards, excluding setup and queues.
Baseline: shared runner only → this PR. Each provider PR is measured independently. Small differences include run-to-run variation; these are shard timings, not full-CI savings. Node 20 is excluded because the baseline Mistral abort/timeout test failed its 15-second timeout.
Bun 1.4 was slower in unchanged shard 3 (1:53 → 3:57); the changed Vercel suites run in shard 5.